import { inject, injectable, multiInject } from "inversify";
import { Terminal } from "vscode";
import { ITerminalActivator, TerminalActivationOptions } from "../../../terminals/types";
import { IConfigurationService } from "../../types";
import { ITerminalActivationHandler, ITerminalHelper } from "../types";
import { BaseTerminalActivator } from "./base";

@injectable()
export class TerminalActivator implements ITerminalActivator {
  protected baseActivator!: ITerminalActivator;
  private pendingActivations = new WeakMap<Terminal, Promise<boolean>>();
  constructor(
    @inject(ITerminalHelper) readonly helper: ITerminalHelper,
    @multiInject(ITerminalActivationHandler) private readonly handlers: ITerminalActivationHandler[],
    @inject(IConfigurationService) private readonly configurationService: IConfigurationService,
  ) {
    this.initialize();
  }
  activateEnvironmentInTerminal(terminal: Terminal, options?: TerminalActivationOptions): Promise<boolean> {
    throw new Error("118Method not implemented.");
  }
  protected initialize() {
    this.baseActivator = new BaseTerminalActivator(this.helper);
  }
}